package com.entity;

import com.util.LocalInformation;
import org.apache.commons.lang3.StringUtils;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import java.util.List;

/**
 * Created by wlc on 2018/3/27.
 */
public class Qm {
    /**
     * 静态属性
     */
    private Date date;
    private ArrayList<String> QM_USER_AND_PBC;
    private ArrayList<String> QM_Calculation_object;
    private ArrayList<String> QM_Electronic_Structure_Quantum_Mechanics_Calculation;
    private ArrayList<String> QM_Ground_state_excited_state;

    /**
     * 动态属性
     */

    public Qm(){
        date = new Date();
    }

    /**
     *数据成员设置和获取函数
     */
    public Date getDate(){
        return this.date;
    }

    public void setQM_USER_AND_PBC(String part1){
        ArrayList<String> temp_QM_USER_AND_PBC = new ArrayList<String>(Arrays.asList(part1.split("wlcniubi")));
        int[] time= LocalInformation.getNowDate(date);
        temp_QM_USER_AND_PBC.add(2, time[0] + "-" + time[1] + "-" + time[2]);
        QM_USER_AND_PBC = temp_QM_USER_AND_PBC;
    }

    public ArrayList<String> getQM_USER_AND_PBC(){
        return this.QM_USER_AND_PBC;
    }

    public void setQM_Calculation_object(String part2){
        ArrayList<String> temp_QM_Calculation_object = new ArrayList<String>(Arrays.asList(part2.split("wlcniubi")));
        temp_QM_Calculation_object.add(0,QM_USER_AND_PBC.get(0));
        QM_Calculation_object = temp_QM_Calculation_object;
    }

    public ArrayList<String> getQM_Calculation_object(){
        return this.QM_Calculation_object;
    }

    public void setQM_Electronic_Structure_Quantum_Mechanics_Calculation(String part3){
        ArrayList<String> temp_QM_Electronic_Structure_Quantum_Mechanics_Calculation = new ArrayList<>(Arrays.asList(part3.split("wlcniubi")));
        temp_QM_Electronic_Structure_Quantum_Mechanics_Calculation.add(0,QM_USER_AND_PBC.get(0));
        QM_Electronic_Structure_Quantum_Mechanics_Calculation = temp_QM_Electronic_Structure_Quantum_Mechanics_Calculation;
    }

    public ArrayList<String> getQM_Electronic_Structure_Quantum_Mechanics_Calculation(){
        return this.QM_Electronic_Structure_Quantum_Mechanics_Calculation;
    }

    public void setQM_Ground_state_excited_state(String part4){
        ArrayList<String> temp_QM_Ground_state_excited_state = new ArrayList<>(Arrays.asList(part4.split("wlcniubi")));
        temp_QM_Ground_state_excited_state.add(0,QM_USER_AND_PBC.get(0));
        QM_Ground_state_excited_state = temp_QM_Ground_state_excited_state;

    }

    public ArrayList<String> getQM_Ground_state_excited_state(){
        return this.QM_Ground_state_excited_state;
    }

}
